// 注：此文件的用途是“为与SKU相关的接口定义TS数据类型”
// 为所有接口的响应数据中都拥有的属性（字段）（也就是“公共属性”）定义TS类型↓
export interface typeOfCommonPropertyInTheResponseDataOfAllOfTheApis {
    code: number,
    message: string,
    ok: boolean,
}
// 为“存储了某个平台属性的相关信息”的对象定义TS类型↓
interface typeOfObjectThatRepresentsAPlatformAttribute {
    attrId: number | string,
    valueId: number | string,
    id?:number,
}
// 为“存储了某个SKU的销售属性值的相关信息”的对象定义TS类型↓
interface typeOfObjectThatRepresentsASkuSaleAttributeValue {
    saleAttrId: number | string,
    saleAttrValueId: number | string,
    id?:number,
}
// 为“存储了某个SKU的相关信息”的对象定义TS类型↓
export interface typeOfObjectThatRepresentsAnSku {
    // 注：以下属性全部是“可选属性”的原因是：在“sku管理”模块中，变量“theDetailInformationOfAnSku”的类型是“typeOfObjectThatRepresentsAnSku”，但其“初始值”是“{}”。为避免“VSCode”标红报错，所以将以下属性全部设置为“可选”↓
    skuAttrValueList?: typeOfObjectThatRepresentsAPlatformAttribute[],
    skuSaleAttrValueList?: typeOfObjectThatRepresentsASkuSaleAttributeValue[],
    spuId?: number | string,
    price?: number | string,
    skuName?: string,
    skuDesc?: string,
    weight?: number,
    tmId?: number | string,
    category3Id?: number | string,
    skuDefaultImg?: string,
    isSale?: number, // 注：这个属性被用于控制SKU是否已上架。可取的值及其含义：1:上架；0:下架
    id?: number,
}
// 为“获取SKU列表”接口的响应数据定义TS类型↓
export interface typeOfResponseDataOfTheApiThatGetSkuList extends typeOfCommonPropertyInTheResponseDataOfAllOfTheApis {
    data: {
        records:typeOfObjectThatRepresentsAnSku[],
        total: number,
        size: number,
        current: number,
        orders: [],
        optimizeCountSql: boolean,
        searchCount: boolean,
        pages: number,
        hitCount: boolean,
        countId: null,
        maxLimit: null,
    },
}
// 为“获取SKU详情信息”接口的响应数据定义TS类型↓
export interface typeOfResponseDataOfTheApiThatGetSkuDetailInformation extends typeOfCommonPropertyInTheResponseDataOfAllOfTheApis {
    data: typeOfObjectThatRepresentsAnSku,
}